package com.bdqn.petmalldemo.config;

import org.springframework.context.annotation.Configuration;
import org.springframework.web.servlet.config.annotation.ResourceHandlerRegistry;
import org.springframework.web.servlet.config.annotation.WebMvcConfigurer;

/**
 * @Author:彭俊
 * @description:WEB配置
 * @date:2020-03-25 22:25
 */
@Configuration
public class WebMvcConfig implements WebMvcConfigurer {

  /*  @Value("${qr.path}")
    private  String qrPath;*/
    @Override
    public void addResourceHandlers(ResourceHandlerRegistry registry) {
        registry
                //被访问的相对路径
                .addResourceHandler("/upload/alipay/**")
                //服务器的绝对路径
                .addResourceLocations("F:\\zy\\Y2\\xm\\pet-mall-demo\\target\\classes\\static\\upload\\alipay\\");
    }
}
